#pragma once

#include "SDL.h"

class SDLTime
{
#pragma region Singleton
public:
	static SDLTime* GetInstance()
	{
		if(!mInstance)
		{
			mInstance = new SDLTime();
		}
		return mInstance;
	}
	static void Kill()
	{
		delete mInstance;
		mInstance = 0;
	}
private:
	static SDLTime* mInstance;
	SDLTime();
	~SDLTime();
#pragma endregion

public:
	float GetDeltaTime(){ return mDeltaTime;}
	void Tick();
private:
	float mDeltaTime;
	float mLastTime;
};